<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>使用promise封ajax请求</title>
</head>
<body>
    
</body>
<script src="./js/PromiseAjax.js"></script>
<script>
    // 用Promise这个方法写的请求，逻辑更加的清晰 
    myajax('./js/a.js').then((res)=>{
        console.log(res)
        return myajax('./js/b.js')
    },(res)=>{
        // console.log(res)
        
    }).then((ress)=>{
        console.log(ress)
    },()=>{})
</script>
</html>